package org.lds.message.center.common.util;

import org.apache.commons.collections4.MapUtils;

import java.util.Map;
import java.util.Properties;

public class PropertiesUtil {
    public static Properties getProperties(Map<String, String> propertiesMap) {
        if (MapUtils.isEmpty(propertiesMap)) return null;
        Properties properties = new Properties();
        propertiesMap.forEach((key, value) -> properties.setProperty(key, value));
        return properties;
    }
}
